home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Aminet 8
/
Aminet 8 (1995)(GTI - Schatztruhe)[!][Oct 1995].iso
/
Aminet
/
util
/
misc
/
EasyElements.lha
/
EasyElements
/
Source
/
EEloop.c
< prev
next >
Wrap
Text File
|
1994-12-28
|
757b
|
46 lines
mainloop()
{
while (!terminated)
{
Wait( 1<<EasyElementsWnd->UserPort->mp_SigBit);
while ((!terminated) && (imsg = GT_GetIMsg(EasyElementsWnd->UserPort)))
{
gad = (struct Gadget *)imsg->IAddress;
imsgClass = imsg->Class;
imsgCode = imsg->Code;
GT_ReplyIMsg(imsg);
switch (imsgClass)
{
case IDCMP_CLOSEWINDOW:
terminated = TRUE;
break;
case IDCMP_REFRESHWINDOW:
GT_BeginRefresh(EasyElementsWnd);
GT_EndRefresh(EasyElementsWnd,TRUE);
break;
case IDCMP_GADGETUP:
switch (gad->GadgetID)
{
case GD_Input:
input = (((struct StringInfo *)gad->SpecialInfo)->Buffer);
pressed_Input();
break;
}
default:
break;
}
}
}
}